<?php
/* 微信小程序的api接口的父级控制器 */

namespace App\Http\Controllers;

class MiniController extends Controller

{
    //定义内部变量，存放登录用户信息，供子类共享
    protected $user_id;     //用户id
    protected $validator_message;   //验证器验证提示信息


    public function __construct($except = '') {
        parent::__construct();
        //验证用户身份
        /* $this->middleware('access', ['except' => $except]);

        $this->middleware(function ($request, $next) {
            //登录用户信息初始化
            $this->user_id = isset($request->user_id) ? $request->user_id : '';
            return $next($request);
        }); */
        
    }

}
